﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using ScpControl;

namespace ScpServer
{
    public partial class BetterDS4Options : Form
    {
        public BetterDS4Options() {
            InitializeComponent();
        }

        private void BetterDS4Options_Load(object sender, EventArgs e) {
            chkExclusive.Checked = Global.getDeviceSharingModeIsExclusive();
            chkFlushHIDQueues.Checked = Global.getFlushHIDQueues();

            chkExclusive.Enabled = true;
            chkFlushHIDQueues.Enabled = true;
        }

        private void chkExclusive_CheckedChanged(object sender, EventArgs e) {
            if (chkExclusive.Enabled) {
                Global.setDeviceSharingModeIsExclusive(chkExclusive.Checked);
            }
        }

        private void chkFlushHIDQueues_CheckedChanged(object sender, EventArgs e) {
            if (chkFlushHIDQueues.Enabled) {
                Global.setFlushHIDQueues(chkFlushHIDQueues.Checked);
            }
        }
    }
}
